feat(mcp): logan_evidence_pack — one compact briefing, fetched first#31
Open
ozgesolidkey wants to merge 1 commit into
Open
feat(mcp): logan_evidence_pack — one compact briefing, fetched first#31ozgesolidkey wants to merge 1 commit into
ozgesolidkey wants to merge 1 commit into
Conversation
Adds a composed MCP tool + POST /api/evidence-pack endpoint that assembles one small briefing from existing primitives (analyze + time-gaps + trend-fields + optional baseline delta): severity, level counts, crashes grouped by keyword, top failing components, top time gaps, the discovered field vocabulary, and filter hints. Returns viewerLine references + counts (with truncation flags), NOT raw log text — so the agent works by-reference instead of dozens of exploratory round-trips. - Server composes in-process via ctx.* calls (no extra HTTP hops); analysis runs first so an optional baselineId delta works in the same call. - Journaled as one replayable investigation step (/api/evidence-pack). - Implements step 2 of docs/GRANULARIZATION_DESIGN.md; doc + CLAUDE.md tool table updated to mark it built. Build green, 319 tests pass. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements step 2 of
docs/GRANULARIZATION_DESIGN.md: the evidence pack — one compact briefing the agent fetches first, so it works by-reference instead of dozens of exploratory round-trips.What it adds
logan_evidence_packMCP tool (src/mcp-server/index.ts) →POST /api/evidence-pack(src/main/api-server.ts).analyze+detectTimeGaps+trendDiscoverFields+ optional baselinecompare.logan_triage), level counts with error/warn %, crashes grouped by keyword (firstviewerLine), top failing components, top time gaps (viewerLine+ seconds), the discovered field vocabulary (name/type/occurrences/examples), filter hints, and an optional baselineDelta.viewerLinereferences + counts, not raw log text, withcapstruncation flags so a top-N never reads as "everything".baselineIddelta works in the same call./api/evidence-packadded toINVESTIGATIVE_PATHS+ ajournalLabelbranch).Docs
docs/GRANULARIZATION_DESIGN.md— marked evidence-pack built, reordered build steps.CLAUDE.md— added the tool to the Key MCP Tools table.Verification
npm run buildgreen (main + mcp-server dist emitted).npm test— 319/319 pass.logan_evidence_packon an open file to confirm the briefing shape before merge.🤖 Generated with Claude Code